<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006-2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

namespace think;

global $_W,$_GPC;

defined('MODULE_NAME') or define('MODULE_NAME',$_GPC['m']);

$mod = $_GPC['do'] ? $_GPC['do'] : 'index';
$opt = isset($_GPC['opt']) ? $_GPC['opt'] : 'index';
$_GPC['opt'] = $opt = strtolower(trim(preg_replace("/[A-Z]/", "_\\0", $opt), "_"));
$act = isset($_GPC['act']) ? trim($_GPC['act']) : 'index';

require __DIR__ . '/../thinkphp/base.php';

Container::get('app')->path(dirname(__DIR__) . '/application/')->bind("{$mod}/{$opt}/{$act}")->run()->send();